<?php


namespace app\api\validate;


use app\common\validate\BaseValidate;

class CartValidate extends BaseValidate
{
    protected $rule = [
        'goods_id' => 'require',
        'sku_id' => 'require',
        'sku_name' => 'require',
        'num' => 'require',
    ];

    protected $field = [
        'goods_id' => '商品id',
        'sku_id' => 'sku_id',
        'sku_name' => 'SKU标识',
        'num' => '数量',
    ];
    protected $scene = [
        "deleteSku" => [
            'goods_id',
            'sku_id',
        ],
        "add" => [
            'goods_id',
            'sku_id',
            'sku_name',
            'num',
        ],
        "edit" => [
            'goods_id',
            'sku_id',
            'sku_name',
            'num',
        ],
    ];
}